<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>MTB CAT1 Peripheral driver library: General</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><a href="http://www.cypress.com/"><img alt="Logo" src="IFXCYP_one-line.png"/></a></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">MTB CAT1 Peripheral driver library</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('group__group__syspm__functions__general.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">General<div class="ingroups"><a class="el" href="group__group__syspm.html">SysPm        (System Power Management)</a> &raquo; <a class="el" href="group__group__syspm__functions.html">Functions</a></div></div>  </div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">General Description</h2>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga05204555cfdd18da26aa8e615359484f"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#ga05204555cfdd18da26aa8e615359484f">Cy_SysPm_SetSRAMMacroPwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a> sramNum, uint32_t sramMacroNum, <a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a> sramPwrMode)</td></tr>
<tr class="memdesc:ga05204555cfdd18da26aa8e615359484f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to set Power Mode for each of the Macro in a particular SRAM.  <a href="#ga05204555cfdd18da26aa8e615359484f">More...</a><br /></td></tr>
<tr class="separator:ga05204555cfdd18da26aa8e615359484f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaad339304ab3d1f6f0201f6ef1297c856"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#gaad339304ab3d1f6f0201f6ef1297c856">Cy_SysPm_GetSRAMMacroPwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a> sramNum, uint32_t sramMacroNum)</td></tr>
<tr class="memdesc:gaad339304ab3d1f6f0201f6ef1297c856"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to get Power Mode for each of the Macro in a particular SRAM.  <a href="#gaad339304ab3d1f6f0201f6ef1297c856">More...</a><br /></td></tr>
<tr class="separator:gaad339304ab3d1f6f0201f6ef1297c856"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga42e3e9a5780971ac8dc0f84519f9cac5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#ga42e3e9a5780971ac8dc0f84519f9cac5">Cy_SysPm_SetSRAMPwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a> sramNum, <a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a> sramPwrMode)</td></tr>
<tr class="memdesc:ga42e3e9a5780971ac8dc0f84519f9cac5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to set Power Mode for all the Macros for a particular SRAM.  <a href="#ga42e3e9a5780971ac8dc0f84519f9cac5">More...</a><br /></td></tr>
<tr class="separator:ga42e3e9a5780971ac8dc0f84519f9cac5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga338c546bbd9227c75ada5bc85b1bf615"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#ga338c546bbd9227c75ada5bc85b1bf615">Cy_SysPm_SetSOCMemPartActivePwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a> socmemSramPartNum, <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a> socmemSramPwrMode)</td></tr>
<tr class="memdesc:ga338c546bbd9227c75ada5bc85b1bf615"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set Active mode Power Mode for a particular partition of SRAM in SOCMEM.  <a href="#ga338c546bbd9227c75ada5bc85b1bf615">More...</a><br /></td></tr>
<tr class="separator:ga338c546bbd9227c75ada5bc85b1bf615"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaaf1abb0c8670b67d9bfb299d9d77a990"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#gaaf1abb0c8670b67d9bfb299d9d77a990">Cy_SysPm_SetSOCMemPartDsPwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a> socmemSramPartNum, <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a> socmemSramPwrMode)</td></tr>
<tr class="memdesc:gaaf1abb0c8670b67d9bfb299d9d77a990"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set DS mode Power Mode for a particular partition of SRAM in SOCMEM.  <a href="#gaaf1abb0c8670b67d9bfb299d9d77a990">More...</a><br /></td></tr>
<tr class="separator:gaaf1abb0c8670b67d9bfb299d9d77a990"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga2851806aea4e38ff40c277841c07572c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#ga2851806aea4e38ff40c277841c07572c">Cy_SysPm_GetSOCMemSramPartActivePwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a> socmemSramPartNum)</td></tr>
<tr class="memdesc:ga2851806aea4e38ff40c277841c07572c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to get Active mode Power Mode for a particular SOCMEM SRAM Partition.  <a href="#ga2851806aea4e38ff40c277841c07572c">More...</a><br /></td></tr>
<tr class="separator:ga2851806aea4e38ff40c277841c07572c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gac056944172fccc3eb347a6ce4d62f320"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#gac056944172fccc3eb347a6ce4d62f320">Cy_SysPm_GetSOCMemSramPartDsPwrMode</a> (<a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a> socmemSramPartNum)</td></tr>
<tr class="memdesc:gac056944172fccc3eb347a6ce4d62f320"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to get DS mode Power Mode for a particular SOCMEM SRAM Partition.  <a href="#gac056944172fccc3eb347a6ce4d62f320">More...</a><br /></td></tr>
<tr class="separator:gac056944172fccc3eb347a6ce4d62f320"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gaf98b0b378f526cf5542b946c8dcf74ee"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#gaf98b0b378f526cf5542b946c8dcf74ee">Cy_SysPm_WriteVoltageBitForFlash</a> (<a class="el" href="group__group__syspm__data__enumerates.html#gab60333c26a4265095d1d082e5b153cb5">cy_en_syspm_flash_voltage_bit_t</a> value)</td></tr>
<tr class="memdesc:gaf98b0b378f526cf5542b946c8dcf74ee"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function that changes the voltage setting for flash.  <a href="#gaf98b0b378f526cf5542b946c8dcf74ee">More...</a><br /></td></tr>
<tr class="separator:gaf98b0b378f526cf5542b946c8dcf74ee"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gad4960d176e56bce8631015843a143e1b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#gad4960d176e56bce8631015843a143e1b">Cy_SysPm_SaveRegisters</a> (<a class="el" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> *regs)</td></tr>
<tr class="separator:gad4960d176e56bce8631015843a143e1b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga300fc24bbd19d12771dc2dd472658ab7"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__syspm__functions__general.html#ga300fc24bbd19d12771dc2dd472658ab7">Cy_SysPm_RestoreRegisters</a> (<a class="el" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> const *regs)</td></tr>
<tr class="separator:ga300fc24bbd19d12771dc2dd472658ab7"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a id="ga05204555cfdd18da26aa8e615359484f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga05204555cfdd18da26aa8e615359484f">&#9670;&nbsp;</a></span>Cy_SysPm_SetSRAMMacroPwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a> Cy_SysPm_SetSRAMMacroPwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>&#160;</td>
          <td class="paramname"><em>sramNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>sramMacroNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a>&#160;</td>
          <td class="paramname"><em>sramPwrMode</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function to set Power Mode for each of the Macro in a particular SRAM. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">sramNum</td><td>SRAM's index number has to be passed ex: CY_SYSPM_SRAM0_MEMORY or CY_SYSPM_SRAM1_MEMORY or CY_SYSPM_SRAM2_MEMORY See <a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>.</td></tr>
    <tr><td class="paramname">sramMacroNum</td><td>Macro number of a particular SRAM.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>If SRAM1 and SRAM2 consists of single power partition, power mode will be applied to whole SRAM region, so 0 must be passed for sramMacroNum parameter.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">sramPwrMode</td><td>Power Mode that needs to be set.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>CY_SYSPM_SUCCESS - SRAM MACRO power mode is set.</li>
<li>CY_SYSPM_BAD_PARAM - Input parameters are out of range. See <a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>.</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>CAT1B and CAT1D devices do not support CY_SYSPM_SRAM_PWR_MODE_RET, only CY_SYSPM_SRAM_PWR_MODE_ON and CY_SYSPM_SRAM_PWR_MODE_OFF power modes are supported.</dd></dl>
<p>For the PSoC 64 devices there are possible situations when function returns the PRA error status code. This is because for PSoC 64 devices the function uses the PRA driver to change the protected registers. Refer to <a class="el" href="group__group__pra__enums.html#ga60be13e12e82986f8c0d6c6a6d4f12c5">cy_en_pra_status_t</a> for more details. </p>

</div>
</div>
<a id="gaad339304ab3d1f6f0201f6ef1297c856"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaad339304ab3d1f6f0201f6ef1297c856">&#9670;&nbsp;</a></span>Cy_SysPm_GetSRAMMacroPwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a> Cy_SysPm_GetSRAMMacroPwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>&#160;</td>
          <td class="paramname"><em>sramNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t&#160;</td>
          <td class="paramname"><em>sramMacroNum</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function to get Power Mode for each of the Macro in a particular SRAM. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">sramNum</td><td>SRAM's index number has to be passed ex: CY_SYSPM_SRAM0_MEMORY or CY_SYSPM_SRAM1_MEMORY or CY_SYSPM_SRAM2_MEMORY See <a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>.</td></tr>
    <tr><td class="paramname">sramMacroNum</td><td>Macro number of a particular SRAM.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>If SRAM1 and SRAM2 consists of single power partition, power mode will be applied to whole SRAM region, so 0 must be passed for sramMacroNum parameter, and the power mode obtained will be for whole SRAM.</dd>
<dd>
CAT1B and CAT1D devices do not support CY_SYSPM_SRAM_PWR_MODE_RET, only CY_SYSPM_SRAM_PWR_MODE_ON and CY_SYSPM_SRAM_PWR_MODE_OFF power modes are supported.</dd></dl>
<dl class="section return"><dt>Returns</dt><dd>Returns SRAM power mode. See <a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a>. </dd></dl>

</div>
</div>
<a id="ga42e3e9a5780971ac8dc0f84519f9cac5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga42e3e9a5780971ac8dc0f84519f9cac5">&#9670;&nbsp;</a></span>Cy_SysPm_SetSRAMPwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a> Cy_SysPm_SetSRAMPwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>&#160;</td>
          <td class="paramname"><em>sramNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#ga9d90d8779ef4bda0c99d42ef42eab23d">cy_en_syspm_sram_pwr_mode_t</a>&#160;</td>
          <td class="paramname"><em>sramPwrMode</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function to set Power Mode for all the Macros for a particular SRAM. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">sramNum</td><td>SRAM's index number has to be passed ex: CY_SYSPM_SRAM0_MEMORY or CY_SYSPM_SRAM1_MEMORY or CY_SYSPM_SRAM2_MEMORY See <a class="el" href="group__group__syspm__data__enumerates.html#ga681ab279dc7009abfcdf75af3b6ee48f">cy_en_syspm_sram_index_t</a>.</td></tr>
    <tr><td class="paramname">sramPwrMode</td><td>Power Mode that needs to be set.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>CY_SYSPM_SUCCESS - SRAM power mode is set.</li>
<li>CY_SYSPM_BAD_PARAM - Input parameters are out of range. See <a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>.</li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>CAT1B and CAT1D devices do not support CY_SYSPM_SRAM_PWR_MODE_RET, only CY_SYSPM_SRAM_PWR_MODE_ON and CY_SYSPM_SRAM_PWR_MODE_OFF power modes are supported.</dd></dl>
<p>For the PSoC 64 devices there are possible situations when function returns the PRA error status code. This is because for PSoC 64 devices the function uses the PRA driver to change the protected registers. Refer to <a class="el" href="group__group__pra__enums.html#ga60be13e12e82986f8c0d6c6a6d4f12c5">cy_en_pra_status_t</a> for more details. </p>

</div>
</div>
<a id="ga338c546bbd9227c75ada5bc85b1bf615"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga338c546bbd9227c75ada5bc85b1bf615">&#9670;&nbsp;</a></span>Cy_SysPm_SetSOCMemPartActivePwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a> Cy_SysPm_SetSOCMemPartActivePwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPartNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPwrMode</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set Active mode Power Mode for a particular partition of SRAM in SOCMEM. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">socmemSramPartNum</td><td>SOCMEM- SRAM's Partition Number See <a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>.</td></tr>
    <tr><td class="paramname">socmemSramPwrMode</td><td>Power Mode that needs to be set. See <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>CY_SYSPM_SUCCESS - SRAM power mode is set.</li>
<li>CY_SYSPM_BAD_PARAM - Input parameters are out of range. See <a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>. </li>
</ul>
</dd></dl>

</div>
</div>
<a id="gaaf1abb0c8670b67d9bfb299d9d77a990"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaaf1abb0c8670b67d9bfb299d9d77a990">&#9670;&nbsp;</a></span>Cy_SysPm_SetSOCMemPartDsPwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a> Cy_SysPm_SetSOCMemPartDsPwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPartNum</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPwrMode</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Set DS mode Power Mode for a particular partition of SRAM in SOCMEM. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">socmemSramPartNum</td><td>SOCMEM- SRAM's Partition Number See <a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>.</td></tr>
    <tr><td class="paramname">socmemSramPwrMode</td><td>Power Mode that needs to be set. See <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>CY_SYSPM_SUCCESS - SRAM power mode is set.</li>
<li>CY_SYSPM_BAD_PARAM - Input parameters are out of range. See <a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>. </li>
</ul>
</dd></dl>

</div>
</div>
<a id="ga2851806aea4e38ff40c277841c07572c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga2851806aea4e38ff40c277841c07572c">&#9670;&nbsp;</a></span>Cy_SysPm_GetSOCMemSramPartActivePwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a> Cy_SysPm_GetSOCMemSramPartActivePwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPartNum</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function to get Active mode Power Mode for a particular SOCMEM SRAM Partition. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">socmemSramPartNum</td><td>SOCMEM- SRAM's Partition Number See <a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns SRAM power mode. See <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>. </dd></dl>

</div>
</div>
<a id="gac056944172fccc3eb347a6ce4d62f320"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gac056944172fccc3eb347a6ce4d62f320">&#9670;&nbsp;</a></span>Cy_SysPm_GetSOCMemSramPartDsPwrMode()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a> Cy_SysPm_GetSOCMemSramPartDsPwrMode </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>&#160;</td>
          <td class="paramname"><em>socmemSramPartNum</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function to get DS mode Power Mode for a particular SOCMEM SRAM Partition. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">socmemSramPartNum</td><td>SOCMEM- SRAM's Partition Number See <a class="el" href="group__group__syspm__data__enumerates.html#gabd96535fd59de612ad3df5aa4a7fbcdd">cy_en_syspm_socmem_sram_partition_index_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Returns SRAM power mode. See <a class="el" href="group__group__syspm__data__enumerates.html#gabf3089d471a2c8668a5afb1c9abf1849">cy_en_syspm_socmem_sram_pwr_mode_t</a>. </dd></dl>

</div>
</div>
<a id="gaf98b0b378f526cf5542b946c8dcf74ee"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gaf98b0b378f526cf5542b946c8dcf74ee">&#9670;&nbsp;</a></span>Cy_SysPm_WriteVoltageBitForFlash()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a> Cy_SysPm_WriteVoltageBitForFlash </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__group__syspm__data__enumerates.html#gab60333c26a4265095d1d082e5b153cb5">cy_en_syspm_flash_voltage_bit_t</a>&#160;</td>
          <td class="paramname"><em>value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Function that changes the voltage setting for flash. </p>
<dl class="section note"><dt>Note</dt><dd>Call this function before system enters ULP mode. Call this function after the system enters LP mode.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">value</td><td>Value to be set in the flash voltage control register. See <a class="el" href="group__group__syspm__data__enumerates.html#gab60333c26a4265095d1d082e5b153cb5">cy_en_syspm_flash_voltage_bit_t</a>.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><ul>
<li>CY_SYSPM_SUCCESS - The voltage is set.</li>
<li>CY_SYSPM_CANCELED - Operation was canceled. Call the function again until the function returns CY_SYSPM_SUCCESS. See <a class="el" href="group__group__syspm__data__enumerates.html#ga601b1cb722cb091133caf33d8ab235ca">cy_en_syspm_status_t</a>. </li>
</ul>
</dd></dl>
<dl class="section note"><dt>Note</dt><dd>This API is available for CAT1A devices.</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    </div><div class="line">    <span class="comment">/* The system may continue operating while the voltage on Vccd </span></div><div class="line"><span class="comment">    * discharges to the new voltage. The time it takes to reach the </span></div><div class="line"><span class="comment">    * new voltage depends on operating conditions, including the load current</span></div><div class="line"><span class="comment">    * on Vccd and external capacitor size.</span></div><div class="line"><span class="comment">    */</span></div><div class="line">    SRSS_PWR_BUCK_CTL = </div><div class="line">    _CLR_SET_FLD32U((SRSS_PWR_BUCK_CTL), SRSS_PWR_BUCK_CTL_BUCK_OUT1_SEL, (uint32_t) <a class="code" href="group__group__syspm__data__enumerates.html#gga3917bcfb5a7b4151ec1b0fcd95c37d5aa0009b3f9bef2d360c1b221cd8c801650">CY_SYSPM_BUCK_OUT1_VOLTAGE_ULP</a>);</div><div class="line"></div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="gad4960d176e56bce8631015843a143e1b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gad4960d176e56bce8631015843a143e1b">&#9670;&nbsp;</a></span>Cy_SysPm_SaveRegisters()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Cy_SysPm_SaveRegisters </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> *&#160;</td>
          <td class="paramname"><em>regs</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>Behavior of this API is IP dependent. <br />
On CAT1A devices: <br />
Saves non-retained UDB registers and the slow and fast clock dividers before system entering system Deep Sleep. Must be called if programmable logic or function are implemented in the UDB array. Cypress ID #280370, #1451. On CAT1B devices: <br />
Saves non-retained UDB registers before system entering system Deep Sleep. Must be called if programmable logic or function are implemented in the UDB array. Cypress ID #280370. </dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Only one CPU on dual CPU devices should call this function. If both CPUs call this function the UDB state restored may be inconsistent with the expected state when restored.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">regs</td><td>The structure where the registers are saved.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>This API is available for CAT1A devices.</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="comment">/* Scenario: There is a need to save the non-retained UDB registers while </span></div><div class="line"><span class="comment">    *  in system Deep Sleep routine.</span></div><div class="line"><span class="comment">    */</span></div><div class="line">    <span class="keyword">static</span> <a class="code" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> regs;</div><div class="line">    </div><div class="line">    <span class="comment">/* Save non-retained UDB registers */</span></div><div class="line">    <a class="code" href="group__group__syspm__functions__general.html#gad4960d176e56bce8631015843a143e1b">Cy_SysPm_SaveRegisters</a>(&amp;regs);</div><div class="line">    </div><div class="line">    SCB_SCR |= SCB_SCR_SLEEPDEEP_Msk;</div><div class="line"></div><div class="line">    __WFI();</div><div class="line"></div><div class="line">    <span class="comment">/* Restore non-retained UDB registers after system Deep Sleep */</span></div><div class="line">    <a class="code" href="group__group__syspm__functions__general.html#ga300fc24bbd19d12771dc2dd472658ab7">Cy_SysPm_RestoreRegisters</a>(&amp;regs);</div></div><!-- fragment --></dd></dl>

</div>
</div>
<a id="ga300fc24bbd19d12771dc2dd472658ab7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga300fc24bbd19d12771dc2dd472658ab7">&#9670;&nbsp;</a></span>Cy_SysPm_RestoreRegisters()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void Cy_SysPm_RestoreRegisters </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> const *&#160;</td>
          <td class="paramname"><em>regs</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">
<dl class="section note"><dt>Note</dt><dd>Behavior of this API is IP dependent. <br />
On CAT1A devices: \ Restores non-retained UDB registers and the slow and fast clock dividers before system entering system Deep Sleep. Must be called if programmable logic or function are implemented in the UDB array. Cypress ID #280370, #1451. On CAT1B devices: \ Restores non-retained UDB registers before system entering system Deep Sleep. Must be called if programmable logic or function are implemented in the UDB array. Cypress ID #280370. </dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Only one CPU on dual CPU devices should call this function. If both CPUs call this function the UDB state restored may be inconsistent with the expected state when restored.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">regs</td><td>The structure with data stored (using <a class="el" href="group__group__syspm__functions__general.html#gad4960d176e56bce8631015843a143e1b">Cy_SysPm_SaveRegisters()</a>) into the required registers after Deep Sleep.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>This API is available for CAT1A devices.</dd></dl>
<dl class="section user"><dt>Function Usage</dt><dd><div class="fragment"><div class="line">    <span class="comment">/* Scenario: There is a need to save the non-retained UDB registers while </span></div><div class="line"><span class="comment">    *  in system Deep Sleep routine.</span></div><div class="line"><span class="comment">    */</span></div><div class="line">    <span class="keyword">static</span> <a class="code" href="structcy__stc__syspm__backup__regs__t.html">cy_stc_syspm_backup_regs_t</a> regs;</div><div class="line">    </div><div class="line">    <span class="comment">/* Save non-retained UDB registers */</span></div><div class="line">    <a class="code" href="group__group__syspm__functions__general.html#gad4960d176e56bce8631015843a143e1b">Cy_SysPm_SaveRegisters</a>(&amp;regs);</div><div class="line">    </div><div class="line">    SCB_SCR |= SCB_SCR_SLEEPDEEP_Msk;</div><div class="line"></div><div class="line">    __WFI();</div><div class="line"></div><div class="line">    <span class="comment">/* Restore non-retained UDB registers after system Deep Sleep */</span></div><div class="line">    <a class="code" href="group__group__syspm__functions__general.html#ga300fc24bbd19d12771dc2dd472658ab7">Cy_SysPm_RestoreRegisters</a>(&amp;regs);</div></div><!-- fragment --></dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part
<div id="nav-path" class="navpath">
    <ul>
        <li class="footer">
            Generated for <b>MTB CAT1 Peripheral driver library</b> by <b>Cypress Semiconductor Corporation</b>.
            All rights reserved.
        </li>
    </ul>
</div>
-->
</body>
</html>
